home *** CD-ROM | disk | FTP | other *** search
- unit CmdBarHack;
-
- interface
-
- // Since "CommandBars" is both a type name and a property name in the Office_TLB
- // unit, we can't call OleVariant.CommandBars from any unit that uses Office_TLB
- // because the compiler will think we're referring to the type name. Therefore,
- // this unit is intended to hack around the problem.
- function GetAppCommandBars(const App: OleVariant): IDispatch;
-
- implementation
-
- function GetAppCommandBars(const App: OleVariant): IDispatch;
- begin
- Result := App.CommandBars;
- end;
-
- end.
-